﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;
using System.IO;
using System.IO.IsolatedStorage;
using System.Windows.Media.Imaging;

namespace VideoPlay.PhoneClient.Converters
{
    public class BoolToUriConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            bool like = (bool)value;

            string localImagePath = like ? "../Images/like.png" : "../Images/unlike.png";
            Uri uri = new Uri(localImagePath, UriKind.Relative);

            return uri;
        }

        public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
